<%@ page language="java" contentType="text/html; charset=utf-8"
    pageEncoding="utf-8"%>
<%@ include file="../Main/top.jsp"%>
<%@ taglib prefix="s" uri="/struts-tags"%>
<%@ taglib uri="/WEB-INF/CustomTag" prefix="customTag"%>

<div class="function_title"><span class="t2"><img src="../images/dqwz.gif">当前位置：专业文件资源管理</span></div>
<div class="function_content">

<div class="addItem">
  <img src="../images/insert_icon.gif"><a href="preInsertMajorFileSrc.action">添加文件</a>
&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;&nbsp;
<img src="../images/edit_icon.png"><a href="../MajorFileSrc/listMajorFileSrc.action?intercept=1">专业文件资源管理</a>
<img src="../images/edit_icon.png"><a href="../MajorFileSrcCate/listMajorFileSrcCate.action?intercept=1">专业文件分类管理</a>
</div>

<div class="search_function">
<form action="searchListMajorFileSrc.action" method="get" name="search_form" id="search_form" >
<input type="hidden" name="intercept" value="1">
<div class="sub_form">文件名称：
  <input type="text" name="majorFileSrc.majorFileName" id="majorFileSrc.majorFileName" value="<s:property value='majorFileSrc.majorFileName' />"></div>
<div class="sub_form">文件描述：
  <input type="text" name="majorFileSrc.majorFileRemark" id="majorFileSrc.majorFileRemark" value="<s:property value='majorFileSrc.majorFileRemark' />"></div>
<div class="sub_form">资源类型：
<select name="majorFileSrc.majorFileType" id="majorFileType">
	<option value="">全部</option>
<s:if test="%{majorFileSrc.majorFileType==1}">
	<option value="1" selected="selected">文档</option>
</s:if>
<s:else>
	<option value="1">文档</option>
</s:else>	
<s:if test="%{majorFileSrc.majorFileType==2}">
	<option value="2" selected="selected">压缩包</option>
</s:if>
<s:else>
	<option value="2">压缩包</option>
</s:else>	
<s:if test="%{majorFileSrc.majorFileType==3}">
	<option value="3" selected="selected">图片</option>
</s:if>
<s:else>
	<option value="3">图片</option>
</s:else>	
<s:if test="%{majorFileSrc.majorFileType==4}">
	<option value="4" selected="selected">Flash</option>
</s:if>
<s:else>
	<option value="4">Flash</option>
</s:else>	
<s:if test="%{majorFileSrc.majorFileType==5}">
	<option value="5" selected="selected">视频</option>
</s:if>
<s:else>
	<option value="5">视频</option>
</s:else>	
<s:if test="%{majorFileSrc.majorFileType==6}">
	<option value="6" selected="selected">音频</option>
</s:if>
<s:else>
	<option value="6">音频</option>
</s:else>	
</select>
</div>
<div class="sub_form">所属分类：
<customTag:treeSelector majorFileCateId="${majorFileSrc.majorFileCategoryId}" type="majorFileSrc" selectName="majorFileCategoryId" notNeedValidation="false" target="search"></customTag:treeSelector>
</div>
<div class="sub_form">所属专业名称：
  <input type="text" name="majorFileSrc.majorName" id="majorFileSrc.majorName" value="<s:property value='majorFileSrc.majorName' />"></div>
<div class="sub_form">创建者：
  <input type="text" name="majorFileSrc.author" id="majorFileSrc.author" value="<s:property value='majorFileSrc.author' />"></div>
<div class="sub_form"><input type="submit" value="搜索" class="button"></div>
</form>
</div>


<form method="post" name="adminMajorFileSrcDel" id="adminMajorFileSrcDel" action="deleteMoreMajorFileSrc.action" >
<input type="submit" name="submit" value="删除选中记录" class="button" onClick="return p_del();"/>
<p><customTag:pages pageNo="${pagination.pageNo}" total="${pagination.totalPage}" theme="text" /></p>
<table width="100%" border="0" cellspacing="0" cellpadding="0" class="listTable">
  <tr class="title_line">
    <td><input type="checkbox" name="select_all" id="select_all" onClick="checkAll()" class="input_noborder"></td>
    <td>序号</td>
    <td>文件名称</td>
    <td>文件描述</td>
    <td>资源类型</td>
    <td>所属专业</td>
    <td>所属分类</td>
    <td>下载地址</td>
    <!--<td>展示地址</td>-->
    <td>创建者</td>
    <td>添加时间</td>
    <td>更新时间</td>
    <td>操作</td>
  </tr>
<s:iterator value="listMajorFileSrc" status="stat">
  <tr>
  	<td><input type="checkbox" name="majorFileSrc.majorFileIdString" id="allid" value="<s:property value='majorFileId' />" class="input_noborder"></td>
    <td><s:property value="#stat.getIndex()+1" /></td>
    <td><s:property value="majorFileName" /></td>
	<td><s:property value="majorFileRemark" /></td>
	<td><s:property value="majorFileTypeName" /></td>	
	<td><s:property value="majorName" /></td>
	<td><s:property value="majorFileCateName" /></td>
	<td><a href="<s:property value="downloadUrl" />" target="_blank">下载</a></td>
	<!--<td><s:property value="showUrl" /></td>-->
	<td><s:property value="author" /></td>
    <td><s:property value="gmtCreatedString" /></td>
    <td><s:property value="gmtModifiedString" /></td>
    <td><!--<div class="br_line"><a href="preUpdateMajorFileSrc.action?majorFileSrc.majorFileId=<s:property value='majorFileId' />">编辑</a> </div>--><div class="br_line">
<a href="deleteMajorFileSrc.action?majorFileSrc.majorFileId=<s:property value='majorFileId' />" onClick="return p_del();">删除</a></div></td>
  </tr>
 </s:iterator>
</table>
<p><customTag:pages pageNo="${pagination.pageNo}" total="${pagination.totalPage}" theme="text" /></p>
<input type="submit" name="submit" value="删除选中记录" class="button" onClick="return p_del();"/>
</form>
</div>

<%@ include file="../Main/bottom.jsp"%>

